<?php
if (! defined ( 'BASEPATH' ))
	exit ( 'No direct script access allowed' );

class Tastreetpic extends CI_Controller {
	
	function __construct() {
		parent::__construct ();
	
	}
	
	public function index() {
		
		$id = (int)$this->uri->segment(2);
		if(!isset($id) || $id == ''){
			$this->load->view('error');
			return ;
		}
		$member = $this->session->userdata ( 'member' );
		/*if($member != null && $member['id'] == $id){
			redirect('member/streetpiclist');
		}*/
		//该会员的信息
		$this->db->select('*');
		$this->db->from('member');
		$this->db->where('id',$id);
		$eData['tamember'] = $this->db->get()->row_array();
		
		
		$this->db->select("picture.*,street.name,street.creator");
		$this->db->from("picture");
		$this->db->join("street","street.id=picture.belongid");
		$this->db->where('type', 2);
		$this->db->where( 'street.manager', $id );
		$this->db->order_by('picture.createtime', 'DESC');
		$photoList = $this->db->get()->result_array ();
		$eData ['photoList'] = $photoList;
		
		$eData['eID'] = $id;
		$this->load->view('tastreetpic',$eData);
	}
	
}

